/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.nxlv2.nomad.businessobjects;

import java.util.ArrayList;

/**
 *
 * @author Nastasia
 */
public class Article {

    private int idBase, idAppli;
    private String libelle, reference;
    private ArrayList<Prix> listPrix;
    private ArrayList<DetailCommande> listDetailCommande;
    private ArrayList<DetailDemande> listDetailDemande;

    public Article() {
    }

    /**
     *
     * @param idBase
     * @param idAppli
     * @param libelle
     * @param reference
     */
    public Article(int idBase, int idAppli, String libelle, String reference) {
        this.idBase = idBase;
        this.idAppli = idAppli;
        this.libelle = libelle;
        this.reference = reference;
    }

    /**
     *
     * @return idBase
     */
    public int getIdBase() {
        return idBase;
    }

    /**
     *
     * @param idBase the idBase to set
     */
    public void setIdBase(int idBase) {
        this.idBase = idBase;
    }

    /**
     *
     * @return idAppli
     */
    public int getIdAppli() {
        return idAppli;
    }

    /**
     *
     * @param idAppli the idAppli to set
     */
    public void setIdAppli(int idAppli) {
        this.idAppli = idAppli;
    }

    /**
     *
     * @return libelle
     */
    public String getLibelle() {
        return libelle;
    }

    /**
     *
     * @param libelle the libelle to set
     */
    public void setLibelle(String libelle) {
        this.libelle = libelle;
    }

    /**
     *
     * @return reference
     */
    public String getReference() {
        return reference;
    }

    /**
     *
     * @param reference the reference to set
     */
    public void setReference(String reference) {
        this.reference = reference;
    }

    /**
     *
     * @return listPrix
     */
    public ArrayList<Prix> getListPrix() {
        return listPrix;
    }

    /**
     *
     * @param listPrix
     */
    public void setListPrix(ArrayList<Prix> listPrix) {
        this.listPrix = listPrix;
    }

    /**
     *
     * @return listDetailCommande
     */
    public ArrayList<DetailCommande> getListDetailCommande() {
        return listDetailCommande;
    }

    /**
     *
     * @param listDetailCommande
     */
    public void setListDetailCommande(ArrayList<DetailCommande> listDetailCommande) {
        this.listDetailCommande = listDetailCommande;
    }

    /**
     *
     * @return listDetailDemande
     */
    public ArrayList<DetailDemande> getListDetailDemande() {
        return listDetailDemande;
    }

    /**
     *
     * @param listDetailDemande
     */
    public void setListDetailDemande(ArrayList<DetailDemande> listDetailDemande) {
        this.listDetailDemande = listDetailDemande;
    }

    /**
     * 
     * @return String
     */
    @Override
    public String toString() {
//        return "Article{" + "idBase=" + idBase + ", idAppli=" + idAppli + ", libelle=" + libelle + ", reference=" + reference + ", listPrix=" + listPrix + ", listDetailCommande=" + listDetailCommande + ", listDetailDemande=" + listDetailDemande + '}';
        return libelle;
    }

    public String toJSONString(){
        return "{\"idBase\":\""+ idBase +"\",\"idAppli\":\""+ idAppli +"\",\"libelle\":\""+ libelle +"\",\"reference\":\""+ reference +"\"}";
    }
}
